<!DOCTYPE html><html lang=ch><head><meta charset=UTF-8><meta name=viewport content="initial-scale=1,maximum-scale=1,user-scalable=no"><meta content=yes name=apple-mobile-web-app-capable><meta content=black name=apple-mobile-web-app-status-bar-style><title>js</title><link rel=stylesheet href=../../css/public/public.css><body><nav class=nav id=nav></nav><article class="page page-detail"><h1 class=article-h1>js 常用公用方法</h1><section class=part><h3>1、new syl.Loading()</h3><ul><li><span id=loading>点击我弹出loading，然后自动关闭</span></li></ul></section><section class=part><h3>2、new syl.PopTips()</h3><ul><li><span id=popTips>点击我弹出popTips</span></li></ul></section></article><script src=../../lib/js/zepto.js></script><script src=../../js/public.js></script><script>$(function(){
	document.getElementById('loading').addEventListener('touchend', function(){
		var loading = new syl.Loading({
			text:'加载中...'
		});
		$('.ui-loading').click(function(){
			loading.close()
		})
	},false);
	
	document.getElementById('popTips').addEventListener('touchend', function(){
		var popTips = new syl.PopTips({
			type: true,
			text: '提示内容',
			btn1: true
		})
	},false);	
})</script>